﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<title>成员管理 - {$_mtagname$} - 群组 - {site.Name}</title>
<script type="text/javascript" src="{site.Dir}_data/SysConfig.js"></script>
<script type="text/javascript" src="{site.Dir}_libs/jquery-min.js"></script>
<script type="text/javascript" src="{site.Dir}_libs/jquery.jtemplates.js"></script>
<script type="text/javascript" src="{site.Dir}scripts/jumbotcms.js?v4"></script>
<link type="text/css" rel="stylesheet" href="{site.Dir}style/global.css" />
<script type="text/javascript" src="{site.Dir}user/otherfiles/styles/common.js"></script>
<link type="text/css" rel="stylesheet" href="{site.Dir}user/otherfiles/styles/common.css" />
<script type="text/javascript">
var pagesize=20;
var page=thispage();
(function(){
	$(document).ready(function(){
		$.ajax({
			type:		"get",
			dataType:	"json",
			data:		"time="+(new Date().getTime()),
			url:		site.Dir + "mtag/view/ajax.aspx?oper=ajaxGetList&mtagid={$_mtagid$}",
			success:	function(data){
				//数据绑定
				if(data.result =="1"){
				}else{
					window.location.href='{site.Dir}user/mtag';
				}
			}
		});
		var id = anchor();
		if(id!="1" && id!="2" && id!="3" && id!="4") id="0";
		aLoad(id);
	});
})();
function aLoad(s) {
	page = "1";
	if(s == "1")
		sort = "&sort=1";
	else if(s == "2")
		sort = "&sort=2";
	else if(s == "3")
		sort = "&sort=3";
	else if(s == "4")
		sort = "&sort=4";
	else
		sort = "";
	ajaxList(page);
}
function ajaxList(currentpage)
{
	//设置选项卡
	for(i=0; i<5; i++)
	{
		$$("tab"+i).className = "";
        
	}

	if(sort == "&sort=1")
		$$("tab1").className = "current";
	else if(sort == "&sort=2")
		$$("tab2").className = "current";
	else if(sort == "&sort=3")
		$$("tab3").className = "current";
	else if(sort == "&sort=4")
		$$("tab4").className = "current";
	else
		$$("tab0").className = "current";
	if(currentpage!=null) page=currentpage;
	$.ajax({
		type:		"get",
		dataType:	"json",
		data:		"page="+currentpage+"&pagesize="+pagesize+"&time="+(new Date().getTime()),
		url:		"ajax.aspx?mtagid={$_mtagid$}&oper=ajaxGetList"+sort,
		error:		function(XmlHttpRequest,textStatus, errorThrown){if(XmlHttpRequest.responseText!=""){alert(XmlHttpRequest.responseText);}},
		success:	function(d){
			switch (d.result)
			{
			case '0':
				JumbotCms.Alert(d.returnval, "0");
				break;
			case '1':
				$("#ajaxList").setTemplateElement("tplList", null, {filter_data: false});
				$("#ajaxList").processTemplate(d);
				$("#ajaxPageBar").html(d.pagerbar);
				break;
			}
		}
	});
}
function ajaxManage(){
	var ids = JoinSelect("selectID");
	var toPower = $("#toPower").val();
	if(ids=="")
	{
		JumbotCms.Alert("没有任何选择项", "0"); 
		return;
	}
	$.ajax({
		type:		"post",
		dataType:	"json",
		data:		"ids="+ids,
		url:		"ajax.aspx?mtagid={$_mtagid$}&oper=ajaxManage&topower="+toPower+"&time="+(new Date().getTime()),
		error:		function(XmlHttpRequest,textStatus, errorThrown){alert(XmlHttpRequest.responseText); },
		success:	function(d){
			switch (d.result)
			{
			case '0':
				JumbotCms.Alert(d.returnval, "0");
				break;
			case '1':
				ajaxList(page);
				break;
			}
		}
	});
}
</script>
<script type="text/javascript" src="{site.Dir}user/otherfiles/scripts/ajax.js"></script>
</head>
<body>
<style>
@import url({site.Dir}user/otherfiles/css/style.css);
#ucmenu{width:600px;}
</style>
<iframe frameborder="0" scrolling="no" src="{site.Dir}user/index/index.aspx?do=header" width="100%" height="76" marginwidth="0" marginheight="0" hspace="0" vspace="0" id="ifheader"></iframe>
<!--顶部结束,中框架开始-->
<div id="wrap">
	<div id="main">
		<div id="app_sidebar">
			<ul class="app_list" id="default_userapp">
				<li class="currently"><img src="{site.Dir}user/otherfiles/image/writer_v2/user_home.gif"><a href="{site.Dir}user/index/index.aspx">用户管理中心</a></li>
			</ul>
			<ul class="app_list" id="my_userapp">
				<li class="hr"></li>
				<li><img src="{site.Dir}user/otherfiles/image/writer_v2/contribute.gif"><a href="{site.Dir}user/contribute/index.aspx" target="_blank">我的投稿</a><em></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/message.gif"><a href="{site.Dir}user/pmlist/index.aspx">短信</a><em><a href="{site.Dir}user/pmsend/index.aspx">发送</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/friend.gif"><a href="{site.Dir}user/friendlist/index.aspx">好友</a><em><a href="{site.Dir}user/friendadd/index.aspx">添加</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/mtag.gif"><a href="{site.Dir}mtag/index/index.aspx">群组</a><em><a href="{site.Dir}user/mtag_thread">话题</a></em></li>
				<li><img src="{site.Dir}user/otherfiles/image/app/favorite.gif"><a href="{site.Dir}user/favorite/index.aspx">收藏夹</a>
			</ul>
		</div>
		<div id="mainarea">
			<h2 class="title"> <img src="{site.Dir}user/otherfiles/image/app/mtag.gif">群组 - {$_mtagname$} </h2>
			<div class="tabs_header">
				<ul class="tabs">
					<li><a href="{site.Dir}mtag/view_setting/index.aspx?mtagid={$_mtagid$}"><span>基本设置</span></a></li>
					<li><a href="{site.Dir}mtag/view_invite/index.aspx?mtagid={$_mtagid$}"><span>邀请好友</span></a></li>
					<li class="active"><a href="{site.Dir}mtag/view_membermanage/index.aspx?mtagid={$_mtagid$}"><span>成员管理</span></a></li>
					<li><a href="{site.Dir}mtag/view_threadmanage/index.aspx?mtagid={$_mtagid$}"><span>话题批量管理</span></a></li>
					<li><a href="{site.Dir}mtag/view/index.aspx?mtagid={$_mtagid$}"><span>返回群组首页</span></a></li>
				</ul>
			</div>
			<div id="content">
				<div id="ajaxList" style="width:640px;"></div>
				<div id="ajaxPageBar" class="pages"> </div>
			</div>
			<div id="sidebar" style="width:150px;">
				<div class="cat">
					<h3>成员级别</h3>
					<ul class="post_list line_list">
						<li id="tab0"><a href="#0" onclick="aLoad('0');">全部成员</a></li>
						<li id="tab1"><a href="#1" onclick="aLoad('1');">群主</a></li>
						<li id="tab2"><a href="#2" onclick="aLoad('2');">普通成员</a></li>
						<li id="tab3"><a href="#3" onclick="aLoad('3');">禁止发言</a></li>
						<li id="tab4"><a href="#4" onclick="aLoad('4');">待审核成员</a></li>
					</ul>
				</div>
			</div>
		</div>
		<!--/mainarea-->
		<div id="bottom"></div>
	</div>
</div>
<iframe frameborder="0" scrolling="no" src="{site.Dir}user/index/index.aspx?do=footer" width="100%" height="50" marginwidth="0" marginheight="0" hspace="0" vspace="0" id="iffooter"></iframe>
</body>
</html>
